﻿using System.ComponentModel.DataAnnotations;

namespace Robotec.NET.Application;

    /// <summary>
    /// 页面配置明细基础输入参数
    /// </summary>
    public class SysPageOptionConfigColumnBaseInput
    {
        /// <summary>
        /// 列描述
        /// </summary>
        public virtual string? label { get; set; }
        
        /// <summary>
        /// 列宽
        /// </summary>
        public virtual int? width { get; set; }
        
        /// <summary>
        /// 隐藏列
        /// </summary>
        public virtual bool? hide { get; set; }
        
        /// <summary>
        /// 是否是搜索框
        /// </summary>
        public virtual bool? search { get; set; }
        
        /// <summary>
        /// 禁用
        /// </summary>
        public virtual bool? disabled { get; set; }
        
        /// <summary>
        ///  列表中可编辑
        /// </summary>
        public virtual bool? cell { get; set; }
        
        /// <summary>
        /// 搜索框宽度
        /// </summary>
        public virtual int? searchLabelWidth { get; set; }
        
        /// <summary>
        /// 位置排序，数字越大位置越靠前
        /// </summary>
        public virtual int? order { get; set; }
        
        /// <summary>
        /// 编辑隐藏
        /// </summary>
        public virtual bool? display { get; set; }
        
        /// <summary>
        ///  列内容超出隐藏
        /// </summary>
        public virtual bool? overHidden { get; set; }
        
        /// <summary>
        /// 固定列
        /// </summary>
        public virtual bool? fixed_ { get; set; }
        
        /// <summary>
        /// 排序
        /// </summary>
        public virtual bool? sortable { get; set; }
        
        /// <summary>
        /// 编辑/新增表单列数
        /// </summary>
        public virtual int? span { get; set; }
        
        /// <summary>
        /// 标题提示语
        /// </summary>
        public virtual string? labelTip { get; set; }
        
        /// <summary>
        /// 新增时是否显示
        /// </summary>
        public virtual bool? addDisplay { get; set; }
        
        /// <summary>
        /// 编辑时是否显示
        /// </summary>
        public virtual bool? editDisplay { get; set; }
        
        /// <summary>
        /// 显示字数限制
        /// </summary>
        public virtual bool? showWordLimit { get; set; }
        
        /// <summary>
        /// 路由路径
        /// </summary>
        public virtual string? configPath { get; set; }
        
        /// <summary>
        /// 列字段名
        /// </summary>
        public virtual string? prop { get; set; }
        
        /// <summary>
        /// 参与自定义列显隐
        /// </summary>
        public virtual bool? showColumn { get; set; }
        
        /// <summary>
        /// 数据字典拉取地址
        /// </summary>
        public virtual string? dicUrl { get; set; }
        
     [SugarColumn(IsJson =true)]
     public virtual object props { get; set; } 
     
     [SugarColumn(IsJson =true)]
     public virtual object dicData { get; set; } 
     
        /// <summary>
        /// 类型
        /// </summary>
        public virtual string? type { get; set; }
        
        /// <summary>
        /// 过滤条件显示列
        /// </summary>
        public virtual bool? filterable { get; set; }
        
        /// <summary>
        /// 是否开启虚拟Dom模式
        /// </summary>
        public virtual bool? virtualize { get; set; }
        
        /// <summary>
        /// 是否为远程搜索
        /// </summary>
        public virtual bool? remote { get; set; }
        
        /// <summary>
        /// 下拉框是否多选
        /// </summary>
        public virtual bool? multiple { get; set; }
        
        /// <summary>
        /// 最大允许选择个数
        /// </summary>
        public virtual int? limit { get; set; }
        
        /// <summary>
        /// 文本最大输入长度
        /// </summary>
        public virtual int? maxlength { get; set; }
        
     [SugarColumn(IsJson =true)]
     public virtual object rules { get; set; } 
     
        /// <summary>
        /// 默认值
        /// </summary>
        public virtual string? value { get; set; }
        
        /// <summary>
        /// 是否日期区间
        /// </summary>
        public virtual bool? searchRange { get; set; }
        
        /// <summary>
        ///  数据字典接口url携带请求参数
        /// </summary>
        public virtual string? dicQuery { get; set; }
        
        /// <summary>
        /// 数据字典接口请求方式
        /// </summary>
        public virtual string? dicMethod { get; set; }
        
        /// <summary>
        /// 数据字典接口url返回数据格式化方法
        /// </summary>
        public virtual string? dicFormatter { get; set; }
        
        /// <summary>
        /// 详情时是否显示
        /// </summary>
        public virtual bool? viewDisplay { get; set; }
        
        /// <summary>
        /// 添加的时候不能修改
        /// </summary>
        public virtual bool? addDisabled { get; set; }
        
        /// <summary>
        /// 编辑的时候不能修改
        /// </summary>
        public virtual bool? editDisabled { get; set; }
        
        /// <summary>
        /// select选择框匹配
        /// </summary>
        public virtual bool? searchFilterable { get; set; }
        
        /// <summary>
        /// 组件名称
        /// </summary>
        public virtual string? component { get; set; }
        
        /// <summary>
        /// 修改样式名称
        /// </summary>
        public virtual string? className { get; set; }
        
        /// <summary>
        /// 级联选择器:可以选择任意一级
        /// </summary>
        public virtual bool? checkStrictly { get; set; }
        
        /// <summary>
        /// 级联选择器:可以选择任意一级(在搜索框中起作用)
        /// </summary>
        public virtual bool? searchCheckStrictly { get; set; }
        
        /// <summary>
        /// 级联菜单展示所有层级
        /// </summary>
        public virtual bool? show_all_levels { get; set; }
        
    }

    /// <summary>
    /// 页面配置明细分页查询输入参数
    /// </summary>
    public class SysPageOptionConfigColumnInput : BasePageInput
    {
        /// <summary>
        /// 关键字查询
        /// </summary>
        public string SearchKey { get; set; }

            /// <summary>
            /// 路由路径
            /// </summary>
            public string? configPath { get; set; }
            
    }

    /// <summary>
    /// 页面配置明细增加输入参数
    /// </summary>
    public class AddSysPageOptionConfigColumnInput : SysPageOptionConfigColumnBaseInput
    {
    }

    /// <summary>
    /// 页面配置明细删除输入参数
    /// </summary>
    public class DeleteSysPageOptionConfigColumnInput : BaseIdInput
    {
    }

    /// <summary>
    /// 页面配置明细更新输入参数
    /// </summary>
    public class UpdateSysPageOptionConfigColumnInput : SysPageOptionConfigColumnBaseInput
    {
        /// <summary>
        /// Id
        /// </summary>
        [Required(ErrorMessage = "Id不能为空")]
        public long? Id { get; set; }
        
    }

    /// <summary>
    /// 页面配置明细主键查询输入参数
    /// </summary>
    public class QueryByIdSysPageOptionConfigColumnInput : DeleteSysPageOptionConfigColumnInput
    {

    }
